home *** CD-ROM | disk | FTP | other *** search
/ Chip 2007 January, February, March & April / Chip-Cover-CD-2007-02.iso / Pakiet bezpieczenstwa / mini Pentoo LiveCD 2006.1 / mpentoo-2006.1.iso / livecd.squashfs / usr / lib / mozilla-firefox / include / webshell / nsIClipboardCommands.h next >
C/C++ Source or Header  |  2006-05-08  |  10KB  |  318 lines

  1. /*
  2.  * DO NOT EDIT.  THIS FILE IS GENERATED FROM nsIClipboardCommands.idl
  3.  */
  4.  
  5. #ifndef __gen_nsIClipboardCommands_h__
  6. #define __gen_nsIClipboardCommands_h__
  7.  
  8.  
  9. #ifndef __gen_nsISupports_h__
  10. #include "nsISupports.h"
  11. #endif
  12.  
  13. /* For IDL files that don't want to include root IDL files. */
  14. #ifndef NS_NO_VTABLE
  15. #define NS_NO_VTABLE
  16. #endif
  17.  
  18. /* starting interface:    nsIClipboardCommands */
  19. #define NS_ICLIPBOARDCOMMANDS_IID_STR "b8100c90-73be-11d2-92a5-00105a1b0d64"
  20.  
  21. #define NS_ICLIPBOARDCOMMANDS_IID \
  22.   {0xb8100c90, 0x73be, 0x11d2, \
  23.     { 0x92, 0xa5, 0x00, 0x10, 0x5a, 0x1b, 0x0d, 0x64 }}
  24.  
  25. /**
  26.  * An interface for embedding clients who wish to interact with
  27.  * the system-wide OS clipboard. Mozilla does not use a private
  28.  * clipboard, instead it places its data directly onto the system 
  29.  * clipboard. The webshell implements this interface.
  30.  *
  31.  * @status FROZEN
  32.  */
  33. class NS_NO_VTABLE nsIClipboardCommands : public nsISupports {
  34.  public: 
  35.  
  36.   NS_DEFINE_STATIC_IID_ACCESSOR(NS_ICLIPBOARDCOMMANDS_IID)
  37.  
  38.   /**
  39.    * Returns whether there is a selection and it is not read-only.
  40.    *
  41.    * @return <code>true</code> if the current selection can be cut,
  42.    *          <code>false</code> otherwise.
  43.    */
  44.   /* boolean canCutSelection (); */
  45.   NS_IMETHOD CanCutSelection(PRBool *_retval) = 0;
  46.  
  47.   /**
  48.    * Returns whether there is a selection and it is copyable.
  49.    *
  50.    * @return <code>true</code> if there is a selection,
  51.    *          <code>false</code> otherwise.
  52.    */
  53.   /* boolean canCopySelection (); */
  54.   NS_IMETHOD CanCopySelection(PRBool *_retval) = 0;
  55.  
  56.   /**
  57.    * Returns whether we can copy a link location.
  58.    *
  59.    * @return <code>true</code> if a link is selected,
  60.    *           <code>false</code> otherwise.
  61.    */
  62.   /* boolean canCopyLinkLocation (); */
  63.   NS_IMETHOD CanCopyLinkLocation(PRBool *_retval) = 0;
  64.  
  65.   /**
  66.    * Returns whether we can copy an image location.
  67.    *
  68.    * @return <code>true</code> if an image is selected,
  69.               <code>false</code> otherwise.
  70.    */
  71.   /* boolean canCopyImageLocation (); */
  72.   NS_IMETHOD CanCopyImageLocation(PRBool *_retval) = 0;
  73.  
  74.   /**
  75.    * Returns whether we can copy an image's contents.
  76.    *
  77.    * @return <code>true</code> if an image is selected,
  78.    *          <code>false</code> otherwise
  79.    */
  80.   /* boolean canCopyImageContents (); */
  81.   NS_IMETHOD CanCopyImageContents(PRBool *_retval) = 0;
  82.  
  83.   /**
  84.    * Returns whether the current contents of the clipboard can be
  85.    * pasted and if the current selection is not read-only.
  86.    *
  87.    * @return <code>true</code> there is data to paste on the clipboard
  88.    *          and the current selection is not read-only,
  89.    *          <code>false</code> otherwise
  90.    */
  91.   /* boolean canPaste (); */
  92.   NS_IMETHOD CanPaste(PRBool *_retval) = 0;
  93.  
  94.   /**
  95.    * Cut the current selection onto the clipboard.
  96.    */
  97.   /* void cutSelection (); */
  98.   NS_IMETHOD CutSelection(void) = 0;
  99.  
  100.   /**
  101.    * Copy the current selection onto the clipboard.
  102.    */
  103.   /* void copySelection (); */
  104.   NS_IMETHOD CopySelection(void) = 0;
  105.  
  106.   /**
  107.    * Copy the link location of the current selection (e.g.,
  108.    * the |href| attribute of a selected |a| tag).
  109.    */
  110.   /* void copyLinkLocation (); */
  111.   NS_IMETHOD CopyLinkLocation(void) = 0;
  112.  
  113.   /**
  114.    * Copy the location of the selected image.
  115.    */
  116.   /* void copyImageLocation (); */
  117.   NS_IMETHOD CopyImageLocation(void) = 0;
  118.  
  119.   /**
  120.    * Copy the contents of the selected image.
  121.    */
  122.   /* void copyImageContents (); */
  123.   NS_IMETHOD CopyImageContents(void) = 0;
  124.  
  125.   /**
  126.    * Paste the contents of the clipboard into the current selection.
  127.    */
  128.   /* void paste (); */
  129.   NS_IMETHOD Paste(void) = 0;
  130.  
  131.   /**
  132.    * Select the entire contents.
  133.    */
  134.   /* void selectAll (); */
  135.   NS_IMETHOD SelectAll(void) = 0;
  136.  
  137.   /**
  138.    * Clear the current selection (if any). Insertion point ends up
  139.    * at beginning of current selection.
  140.    */
  141.   /* void selectNone (); */
  142.   NS_IMETHOD SelectNone(void) = 0;
  143.  
  144. };
  145.  
  146. /* Use this macro when declaring classes that implement this interface. */
  147. #define NS_DECL_NSICLIPBOARDCOMMANDS \
  148.   NS_IMETHOD CanCutSelection(PRBool *_retval); \
  149.   NS_IMETHOD CanCopySelection(PRBool *_retval); \
  150.   NS_IMETHOD CanCopyLinkLocation(PRBool *_retval); \
  151.   NS_IMETHOD CanCopyImageLocation(PRBool *_retval); \
  152.   NS_IMETHOD CanCopyImageContents(PRBool *_retval); \
  153.   NS_IMETHOD CanPaste(PRBool *_retval); \
  154.   NS_IMETHOD CutSelection(void); \
  155.   NS_IMETHOD CopySelection(void); \
  156.   NS_IMETHOD CopyLinkLocation(void); \
  157.   NS_IMETHOD CopyImageLocation(void); \
  158.   NS_IMETHOD CopyImageContents(void); \
  159.   NS_IMETHOD Paste(void); \
  160.   NS_IMETHOD SelectAll(void); \
  161.   NS_IMETHOD SelectNone(void); 
  162.  
  163. /* Use this macro to declare functions that forward the behavior of this interface to another object. */
  164. #define NS_FORWARD_NSICLIPBOARDCOMMANDS(_to) \
  165.   NS_IMETHOD CanCutSelection(PRBool *_retval) { return _to CanCutSelection(_retval); } \
  166.   NS_IMETHOD CanCopySelection(PRBool *_retval) { return _to CanCopySelection(_retval); } \
  167.   NS_IMETHOD CanCopyLinkLocation(PRBool *_retval) { return _to CanCopyLinkLocation(_retval); } \
  168.   NS_IMETHOD CanCopyImageLocation(PRBool *_retval) { return _to CanCopyImageLocation(_retval); } \
  169.   NS_IMETHOD CanCopyImageContents(PRBool *_retval) { return _to CanCopyImageContents(_retval); } \
  170.   NS_IMETHOD CanPaste(PRBool *_retval) { return _to CanPaste(_retval); } \
  171.   NS_IMETHOD CutSelection(void) { return _to CutSelection(); } \
  172.   NS_IMETHOD CopySelection(void) { return _to CopySelection(); } \
  173.   NS_IMETHOD CopyLinkLocation(void) { return _to CopyLinkLocation(); } \
  174.   NS_IMETHOD CopyImageLocation(void) { return _to CopyImageLocation(); } \
  175.   NS_IMETHOD CopyImageContents(void) { return _to CopyImageContents(); } \
  176.   NS_IMETHOD Paste(void) { return _to Paste(); } \
  177.   NS_IMETHOD SelectAll(void) { return _to SelectAll(); } \
  178.   NS_IMETHOD SelectNone(void) { return _to SelectNone(); } 
  179.  
  180. /* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
  181. #define NS_FORWARD_SAFE_NSICLIPBOARDCOMMANDS(_to) \
  182.   NS_IMETHOD CanCutSelection(PRBool *_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->CanCutSelection(_retval); } \
  183.   NS_IMETHOD CanCopySelection(PRBool *_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->CanCopySelection(_retval); } \
  184.   NS_IMETHOD CanCopyLinkLocation(PRBool *_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->CanCopyLinkLocation(_retval); } \
  185.   NS_IMETHOD CanCopyImageLocation(PRBool *_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->CanCopyImageLocation(_retval); } \
  186.   NS_IMETHOD CanCopyImageContents(PRBool *_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->CanCopyImageContents(_retval); } \
  187.   NS_IMETHOD CanPaste(PRBool *_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->CanPaste(_retval); } \
  188.   NS_IMETHOD CutSelection(void) { return !_to ? NS_ERROR_NULL_POINTER : _to->CutSelection(); } \
  189.   NS_IMETHOD CopySelection(void) { return !_to ? NS_ERROR_NULL_POINTER : _to->CopySelection(); } \
  190.   NS_IMETHOD CopyLinkLocation(void) { return !_to ? NS_ERROR_NULL_POINTER : _to->CopyLinkLocation(); } \
  191.   NS_IMETHOD CopyImageLocation(void) { return !_to ? NS_ERROR_NULL_POINTER : _to->CopyImageLocation(); } \
  192.   NS_IMETHOD CopyImageContents(void) { return !_to ? NS_ERROR_NULL_POINTER : _to->CopyImageContents(); } \
  193.   NS_IMETHOD Paste(void) { return !_to ? NS_ERROR_NULL_POINTER : _to->Paste(); } \
  194.   NS_IMETHOD SelectAll(void) { return !_to ? NS_ERROR_NULL_POINTER : _to->SelectAll(); } \
  195.   NS_IMETHOD SelectNone(void) { return !_to ? NS_ERROR_NULL_POINTER : _to->SelectNone(); } 
  196.  
  197. #if 0
  198. /* Use the code below as a template for the implementation class for this interface. */
  199.  
  200. /* Header file */
  201. class nsClipboardCommands : public nsIClipboardCommands
  202. {
  203. public:
  204.   NS_DECL_ISUPPORTS
  205.   NS_DECL_NSICLIPBOARDCOMMANDS
  206.  
  207.   nsClipboardCommands();
  208.  
  209. private:
  210.   ~nsClipboardCommands();
  211.  
  212. protected:
  213.   /* additional members */
  214. };
  215.  
  216. /* Implementation file */
  217. NS_IMPL_ISUPPORTS1(nsClipboardCommands, nsIClipboardCommands)
  218.  
  219. nsClipboardCommands::nsClipboardCommands()
  220. {
  221.   /* member initializers and constructor code */
  222. }
  223.  
  224. nsClipboardCommands::~nsClipboardCommands()
  225. {
  226.   /* destructor code */
  227. }
  228.  
  229. /* boolean canCutSelection (); */
  230. NS_IMETHODIMP nsClipboardCommands::CanCutSelection(PRBool *_retval)
  231. {
  232.     return NS_ERROR_NOT_IMPLEMENTED;
  233. }
  234.  
  235. /* boolean canCopySelection (); */
  236. NS_IMETHODIMP nsClipboardCommands::CanCopySelection(PRBool *_retval)
  237. {
  238.     return NS_ERROR_NOT_IMPLEMENTED;
  239. }
  240.  
  241. /* boolean canCopyLinkLocation (); */
  242. NS_IMETHODIMP nsClipboardCommands::CanCopyLinkLocation(PRBool *_retval)
  243. {
  244.     return NS_ERROR_NOT_IMPLEMENTED;
  245. }
  246.  
  247. /* boolean canCopyImageLocation (); */
  248. NS_IMETHODIMP nsClipboardCommands::CanCopyImageLocation(PRBool *_retval)
  249. {
  250.     return NS_ERROR_NOT_IMPLEMENTED;
  251. }
  252.  
  253. /* boolean canCopyImageContents (); */
  254. NS_IMETHODIMP nsClipboardCommands::CanCopyImageContents(PRBool *_retval)
  255. {
  256.     return NS_ERROR_NOT_IMPLEMENTED;
  257. }
  258.  
  259. /* boolean canPaste (); */
  260. NS_IMETHODIMP nsClipboardCommands::CanPaste(PRBool *_retval)
  261. {
  262.     return NS_ERROR_NOT_IMPLEMENTED;
  263. }
  264.  
  265. /* void cutSelection (); */
  266. NS_IMETHODIMP nsClipboardCommands::CutSelection()
  267. {
  268.     return NS_ERROR_NOT_IMPLEMENTED;
  269. }
  270.  
  271. /* void copySelection (); */
  272. NS_IMETHODIMP nsClipboardCommands::CopySelection()
  273. {
  274.     return NS_ERROR_NOT_IMPLEMENTED;
  275. }
  276.  
  277. /* void copyLinkLocation (); */
  278. NS_IMETHODIMP nsClipboardCommands::CopyLinkLocation()
  279. {
  280.     return NS_ERROR_NOT_IMPLEMENTED;
  281. }
  282.  
  283. /* void copyImageLocation (); */
  284. NS_IMETHODIMP nsClipboardCommands::CopyImageLocation()
  285. {
  286.     return NS_ERROR_NOT_IMPLEMENTED;
  287. }
  288.  
  289. /* void copyImageContents (); */
  290. NS_IMETHODIMP nsClipboardCommands::CopyImageContents()
  291. {
  292.     return NS_ERROR_NOT_IMPLEMENTED;
  293. }
  294.  
  295. /* void paste (); */
  296. NS_IMETHODIMP nsClipboardCommands::Paste()
  297. {
  298.     return NS_ERROR_NOT_IMPLEMENTED;
  299. }
  300.  
  301. /* void selectAll (); */
  302. NS_IMETHODIMP nsClipboardCommands::SelectAll()
  303. {
  304.     return NS_ERROR_NOT_IMPLEMENTED;
  305. }
  306.  
  307. /* void selectNone (); */
  308. NS_IMETHODIMP nsClipboardCommands::SelectNone()
  309. {
  310.     return NS_ERROR_NOT_IMPLEMENTED;
  311. }
  312.  
  313. /* End of implementation class template. */
  314. #endif
  315.  
  316.  
  317. #endif /* __gen_nsIClipboardCommands_h__ */
  318.